Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(metrics): avoid intialize un-necessary system resources #2624

Open
wants to merge 2 commits into
base: stable
Choose a base branch
from

Conversation

maqi
Copy link
Member

@maqi maqi commented Jan 13, 2025

Description

It turned out that new_all function opens FD for un-necessary system resources, which result in accumulated memory-usage issue.
Hence initialize with nothing and then refresh only related.

This PR also contains the CI test to confirm there is no extra and acculuated FDs to be held by the node process.

Type of Change

Please mark the types of changes made in this pull request.

  • Bug fix (non-breaking change which fixes an issue)

@maqi maqi force-pushed the avoid_scan_entire_sys_during_cpu_threshold_check branch from 15f045f to 189f0b7 Compare January 13, 2025 21:32
@maqi maqi changed the base branch from rc-2024.12.1-hotfix5 to stable January 13, 2025 21:33
@maqi maqi force-pushed the avoid_scan_entire_sys_during_cpu_threshold_check branch 2 times, most recently from 0d1c4c4 to 5b66cf4 Compare January 14, 2025 14:57
@maqi maqi changed the title fix(node): avoid scan entire OS during cpu threshold check fix(metrics): avoid holding sysinfo instance for too long time Jan 14, 2025
@maqi maqi force-pushed the avoid_scan_entire_sys_during_cpu_threshold_check branch 3 times, most recently from 83aa553 to 3cc28cd Compare January 15, 2025 10:54
@maqi maqi changed the title fix(metrics): avoid holding sysinfo instance for too long time fix(metrics): avoid intialize un-necessary system resources Jan 15, 2025
maqi added 2 commits January 15, 2025 20:22
It turned out that new_all function opens FD for un-necessary system
resources, which result in accumulated memory-usage issue.
Hence initialize with nothing and then refresh only related.
@maqi maqi force-pushed the avoid_scan_entire_sys_during_cpu_threshold_check branch from 3cc28cd to 146651d Compare January 15, 2025 12:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant